# Contributor: Dmitry Zakharchenko <dmitz@disroot.org>
# Maintainer: Dmitry Zakharchenko <dmitz@disroot.org>
pkgname=py3-stevedore
_pkgname=stevedore
pkgver=3.5.0
pkgrel=1
pkgdesc="Manage dynamic plugins for Python applications"
url="https://github.com/openstack/stevedore"
arch="noarch"
license="Apache-2.0"
depends="python3"
makedepends="py3-setuptools py3-pbr"
checkdepends="py3-pytest py3-testtools py3-docutils py3-sphinx"
source="https://pypi.org/packages/source/s/$_pkgname/$_pkgname-$pkgver.tar.gz"
builddir="$srcdir/$_pkgname-$pkgver"

prepare() {
	default_prepare
	# Remove dependency on pbr; it's not a runtime dependency
	sed -i '/pbr/d' requirements.txt
}

build() {
	python3 setup.py build
}

check() {
	pytest
}

package() {
	python3 setup.py install --prefix=/usr --root="$pkgdir"
}

sha512sums="
be0f82230d7d4d3cf18dd913e11093ad90744e32a3021d9f88f0be244f56d0e3606af0adef67674c569c41d885837be3f0fc4d58009e036151cc67963a4f2ab3  stevedore-3.5.0.tar.gz
"
